...
NCallback(Bool msg){
...
...
...
r_nustate=msg->data;
}
SCallback(UInt8 msg){
r_state=msg->data;
}
Subscribe('NewState',1000, NCallback);
if (r_nustate ==true){
Subscribe('State',1000, SCallback);
}
switch(r_state):
...
This way we only call on that extra subscriber when we need it, and rely on global memory otherwise. I have kind of PTSD from being really careful about the memory from working the Velodyne HDL-32E, since I was having to transfer a lot of pics and clouds at the same time.
Once this is all hashed out, I'll begin testing using the special String publisher I made, then maybe the Drone's LEDs, and then finally the Drone actually taking off and landing. You can never be too careful when playing with the Drone indoors, or for an extended amount of time. Then it's on to the glorious world of IMUs.
On the topic of Velodyne, I'll be making my Velodyne code available on Github slowly. It will be a private repo, and it may take a while because I want to document it really well. I'll make an update when it becomes available.
No comments:
Post a Comment