how set serial enable for the LLP

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

how set serial enable for the LLP

dwenhcil
hello everybody

I am a new user for asctec pelican, although I have follow some peers' instructions to start the motors, but it doesn't work, the I think the question is I have not set the serial enable for the low level processor, then my question is how to set the LL serial 0 enable?

my start motors procedures are as follows:

1. run the asctec_autopilot by the following launch file:
==============================================
<launch>

  #### Asctec Autopilot ###################################

  <node pkg="asctec_autopilot" type="autopilot_node" name="AutoPilotNode" output="screen">

    <remap from="/asctec/ESTOP" to="/mav/estop"/> 
   
   
   

   
   
   

   
   
   
   
  </node>

  #### Asctec Proc ########################################

  <node pkg="asctec_proc" type="asctec_proc_node" name="AsctecProcNode" output="screen">
   
   
   
  </node>
</launch>
=============================================================

and the message publisher is:
===================================
#include "ros/ros.h"
#include "std_msgs/Float64.h"
#include <sstream>
#include "asctec_proc/asctec_proc.h"
int main(int argc, char **argv)
{
  ros::init(argc, argv, "controller");
  ros::NodeHandle n;
  ros::Publisher controller_pub = n.advertise<asctec_msgs::CtrlInput>("/asctec/CTRL_INPUT", 1);
  ros::Rate loop_rate(30);
  while (ros::ok())
  {
    asctec_msgs::CtrlInput msg;
    msg.thrust = 0;
    msg.yaw=-2048;
    msg.ctrl=0xFF;
    msg.pitch=0;
    msg.roll=0;
    msg.chksum=msg.pitch
              +msg.roll+msg.yaw
              +msg.thrust+msg.ctrl+0xAAAA;
    controller_pub.publish(msg);
    ros::spinOnce();
    loop_rate.sleep();
  }
  return 0;
}


===================================
Reply | Threaded
Open this post in threaded view
|

Re: how set serial enable for the LLP

CataLuer
Dear dwenhcil:

      Have you make the motors on finally?

Best wishes!
Reply | Threaded
Open this post in threaded view
|

Re: how set serial enable for the LLP

dwenhcil
yes, I have made the motors start now, we has to switch the futaba to enable it
Reply | Threaded
Open this post in threaded view
|

Re: how set serial enable for the LLP

CataLuer
Thank you, we also switch the stick to the on, this can work when we use zigbee, but we want to Atomboard via UART0 to make motors on, not from zigbee, you know zigbee and UART0 cable(with a loop) are required to connect the LL0, how do you solve this problem, or maybe we have the LL0 configuration problem, it just listen to the zigbee signal, but I measured the CTS from zigbee output is also 0, which is similar to the situation when we use UART cable to put that loop(CTS to 0) !
Reply | Threaded
Open this post in threaded view
|

Re: how set serial enable for the LLP

dwenhcil
CataLuer

I am not quite understand your problem
in my side, I did not use zigbee, I pulled out the zigbee from the LL0, and then insert the UART_C (with a loop). see following image

Reply | Threaded
Open this post in threaded view
|

Re: how set serial enable for the LLP

CataLuer
Sorry, I think our cable connects are the same as yours, but we still can not make motors on via ssh to onboard to send the control commands. We have installed the asctec_drivers, mav_tools and scan_tools from github, but not from ccny git website, because they are "crashed", the laser odometry works perfectly, the only problem for us is that control can not work, could you give us some suggesions?
Reply | Threaded
Open this post in threaded view
|

Re: how set serial enable for the LLP

dwenhcil
have you set the port correctly?
for Xbee, it should be something like: port_ = "/dev/ttyUSB0";
for URAT_x (x depends on which interface you used, I use C), it should be something like port_ = "/dev/ttyS3" (3 here depends on the x you selected);