Queen's Mostly Autonomous Sailboat Team Wiki
Register
Advertisement

[[Category:Article management templates|Template loop detected: Template:Cleanup]]


I've gone through my email inbox for MAST and here's the useful info:

Aug 2[]

Today I looked into serial output, using serialout.c (saved in the Summer2010 folder). I used the wind sensor to test this, and tried to change some settings on it.

PB100TechnicalManual_rev1.007.pdf
We want to test the serial output by changing the wind sensor altitude to 75m (lake ontario). To do this, send (see pg. 39): (*hh is an optional checksum)
$PAMTC,ALT,SET,75,1,2*hh<CR><LF>
To query (see pg. 40): $PAMTR,ALT,Q

This did not appear to work; no PAMTR command was received when we read from the port after sending the Q command. Next meeting, we will turn off automatic transmission of data from the wind sensor and see if it is properly receiving commands from the uC; if it still doesnt work, we will connect the wind sensor directly to the computer (no uC) and get it to work that way first.

$PAMTC,EN changes the speed and which commands are sent by the PB100 (see p. 43-35)
$PAMTC,EN,S saves settings to non-volatile memory


I also looked a bit more into how Zigbee works.

- Changed ATMY on both chips to FFFF to disable 16-bit addressing
- still no minicom
- need minicom to work with Zigbee to wirelessly transfer programs; cannot send programs with the X-CTU terminal program


Here's some zigbee links:
http://www.digi.com/support/kbase/kbaseresultdetl.jsp?id=2187 zigbee addressing knowledge base article - maybe addressing is why only X-CTU works to send to the micro-controller? If we are in broadcast mode then the package could be scrambled by minicom and not checked?
http://www.integral.com.br/downloads/Docs_Embedded/X-CTU%20Manual_C.pdf the X-CTU manual

http://www.circuitsathome.com/mcu/programming/playing-xbee useful(??) microcontroller code to check CTS and buffer status, also using zigbee


July 23[]

amperage fuses **for motors

hack wires to CB

no doubler disconnect

new old elec power circuit

use small prototypes to facilitate larger designs

RC reciever up MAST? cannot lengtehn cable

high current waterproof 2pin connecotr for battery BOTH box and on elec power circuit

reattachpowere plug to xbee dev board

xbee antenas:: fix buy new, yada yada

clean up wind sensor box in general:: make it go

Circuit diagrams and pics for :::::::::::::
  
  patch opto iso
  every cable end 
  multiplexer circuit
  motorpower circuit
  old elec power circuit
  RC mode jumper circuit
  demux  
  General systems diagram

How to's for drilling, mechanical stuff i did

test serial motor controller from Simmons


Posters to make
- how to charge batteries
- things in an emergency repair kit
- sailboats
- diagram of the circuits
- RS232 and other signals info general
- specific information on power and signal info for motors, compass, wind sensor
-

June 15[]

http://www.robotshop.ca/pololu-micro-serial-servo-controller.html the PWM controller that simmons has

http://www.daniweb.com/forums/thread140260.html sample linux RS232 code that doesnt work

http://www.tldp.org/HOWTO/Serial-Programming-HOWTO/x115.html example of input and output processing with RS232

http://www.embeddedarm.com/services/fpga-ipcore-xdio.php great guide to TS7260 XDIO commands

http://www.embeddedarm.com/support/downloads.php FTP with a few more sample programs

http://tech.groups.yahoo.com/group/ts-7000/msearch?query=Linux+2.6&submit=Search&charset=ISO-8859-1 mailing list archive


http://www.embeddedarm.com/about/resource.php?item=441 TS-SER4 expansion board description

http://www.embeddedarm.com/documentation/software/arm-tslinux-ts72xx.pdf programming guide

http://www.embeddedarm.com/documentation/software/arm-linux-ts72xx.pdf programming guide 2

http://groups.yahoo.com/group/ts-7000/ yahoo users group



June 7[]

MAST_software/Serial/serial3.c -> SERIAL3 -> compass COMA, wind COMC -> works to get two readings from everything

MAST_software/Code2/testmerged.c -> SAILMERGED -> now compiles

SERIAL EAGAIN ERROR
SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR
�SERIAL EAGAIN ERROR


MAST_software/Code2/testbest.c -> SAILBEST -> SERAGAIN ERROR read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed
SERIAL EAGAIN ERROR
read failed

MAST_software/Code2/test4.c (testmerged.c) -> SAILMER2 -> working; parsing compass and wind; need to make these global variables
~/Desktop/PWM(2).c -> commented PWM and DIO file
~/Desktop/nmea parser library in a zip
MAST_software/xdio2/xdio/main.c working PWM


ToDo:
- holes in box
- laptop for zigbee
- charge batteries
- check all wiring multiplexers etc work

To use Poloulo:
- set servo numbers -> uneccessary, 0-7 default
- set servo speeds -


==June 15==
On CD labelled TS-Linux there are a few sample programs; no serial example.
manuals folder has schematic of board and manual
Other CD has HC11 stuff on it

The wiki on the TS site is useless.

/MAST_software/xdio2/xdio/main.c PWM program and DIO
/MAST_software/XDIO/xdio/main.c PWM program and DIO original??
/Desktop/main.c ?? original?

/MAST_software/xdio2/xdio/pindirn.c 3 DIO channels working (switches when you enter a number)
/MAST_software/logic.txt rudder and winch RC vs uC logic

/MAST_software/XDIO/xdio/pwm4.c PWM program and DIO
/MAST_software/XDIO/xdio/pwm4.c PWM program and DIO ... not sure what the difference of all these are

June 1[]

Testing - cleaned up some memory management in /Code2/test.c - compiled as SAILTES2 - set permissions to all on SAILTES2 - put on microcontroller - had some trouble transfering the file - minicom -> ctrl+a o File Names and Paths -> changed upload directory to ~/Documents/MAST_software - ran first time: no segfault, did some stuff and then repeated the below (dont know what the stuff was, as infinite scrolling was off in terminal settings) " The array:0.000000 The array:0.000000 The array:0.000000 The array:0.000000 The array:0.0000array:0.000000 "

noticed that the microcontroller sometimes cuts out some of the data it's trying to send (first few letters in a string occasionally)

2nd time running SAILTES2, it didnt take the waypoints (comm fault) and stopped after an error with wind sensor polling:

"

$ ./SAILTES2

____________    ________       ________________  _____________

/ _____/ _ |--/ ____/ /------/ ____/ __ / __ \/ _____/ ____/-->


/ / /_ / /_| |-/ /___/ /------/ /__// / / / /_/ / / / /___/--->


/ /___/ / /__| |/ /___/ /___---/ / / /_/ / / / / /____/ /___ ---->


/_______/_/---|_/_____/_____/--/_/ /_____/_/ |_|______/_____/----->


>


Please enter the number of way p2 The way points are: HE:$WAYP,0 Number of way points: 0 String: $WAYP,0 1: $WAYP 1: 0 Tokenizing complete print array: Please used Radio control to drive the boat to the start lineCompass pollSERIAL EAGAIN ERROR Splitting string "%�i� �v�*�������+�*@z�*%" into tokens: token :+�i� �v������*���+�*@z�* wrong data Polling wind sensorSERIAL EAGAIN ERROR


$ reboot " - did this agin after reboot - downloaded SAILTES2 again - when ran, did "The array:0.000000" again with some stuff in the middle

" $ ./SAILTES2

____________    ________       ________________  _____________

/ _____/ _ |--/ ____/ /------/ ____/ __ / __ \/ _____/ ____/-->


/ / /_ / /_| |-/ /___/ /------/ /__// / / / /_/ / / / /___/--->


/ /___/ / /__| |/ /___/ /___---/ / / /_/ / / / / /____/ /___ ---->


/_______/_/---|_/_____/_____/--/_/ /_____/_/ |_|______/_____/----->


>


Please enter the number of way points, at least 2 (start and finish), maximum 12:2

Please enter the GPS X coordinates of the way point:4413

Please enter the GPS Y coordinates of the way point:07629

Please enter the GPS X coordinates of the way point:4414

Please enter the GPS Y coordinates of the way point:07628 The way points are:

way point #1 is: (4413.000000,7629.000000)
way point #2 is: (4414.000000,7628.000000)HE:$WAYP,2,4413.000000,7629.000000,4414.000000,7628.000000

Number of way points: 2 String: $WAYP,2,4413.000000,7629.000000,4414.000000,7628.000000 1: $WAYP 1: 2 0: 4413.000000 1: 7629.000000 2: 4414.000000 3: 7628.000000 Tokenizing complete print array: The array:4413.000000 The array:7629.000000 The array:4414.000000 The array:7628.000000 Plt to the start lineCompass pollSERIAL EAGAIN ERROR Splitting string "%�i� �v������*���+�*P%" into tokens: token :+�i� �v�*��������+�*P wrong data Polling wind sensorSERIAL EAGAIN ERROR Splitting string "%|�%9���j��$HCHDG,316.3,0.0,E,,*2E%%$WIMWV,76.8,R,1.3,N,A*18%%$HCHDG,316.1,0.0,E,,*2C%%$WIMWV,76.9,R,1.4,N,A*1E%%$: token :+|� token :+9��������j겤�$HCHDG,316.3,0.0,E,,*2E token :+$WIMWV,76.8,R,1.3,N,A*18 token :+$HCHDG,316.1,0.0,E,,*2C token :+$WIMWV,76.9,R,1.4,N,A*1E token :+$GPGLL,,,,,,V,N*64 |� wrong data command is: |� 9���j��$HCHDG,316.3,0.0,E,,*2E wrong data command is: 9��������j��$HCHDG $WIMWV,76.8,R,CHDG,316.1,0.0,E,,*2C valid string command is: $HCHDG The string: HCHDG Heading: 316.100006 Dev: 0.000000 Dev dir: E Var: 0.000000 Var dir: $WIMWV,76.9,R,1.4,N,A*1E valid string command is: $WIMWV $GPGLL,,,,,,V,N*64 valid string command is: $GPGLL The string: GPGLL Lat_dir nmea: 0.000000 Lat: 0.000000 Lat_dir: � �� wrong data ��mmand is: � wrong data command is: ������ L� wrong data command is: L� � wrong data command is:� HE:$WAYP ============this!! error is here. I added this line. :) Number of way points: 717625476 String: $WAYP 1: $WAYP 1: (null) Tokenizing complete print array: The array:52248860.000000 The array:0.000000 The array:nan The array:nan The array:nan The array:nan The array:0.000000 The array:0.000000 The array:0.00e array:0.000000 The array:0.000000 " ...

" The array:0.000000 The array:0.000000 The array:0.000000 The array:52757836.000000 The array:0.000000 The array:3381.312500 The array:74969504085813594321961615360.000000 The array:131537.734375 The array:0.048169 The array:74104956841962234024464220160.000000 The array:3422581760.000000 The array:202695792.000000 The array:74969442695049317016573837312.000000 The array:2206836981760.000000 The array:0.050127 The array:302222866694634751350886887325696.000000 The array:13.000114 The array:0.000000 The array:0.000000 The array:18057256272710291170298691584.000000 The array:17090016023047333872664576.000000 The array:222128184838496875233047140630528.000000 The array:809106787060454260736.000000 The array:0.000000 The array:18057256272710291170298691584.000000 The array:3205.187500 The array:0.000000 The array:0.000000 The array:8617315328.000000 The array:0.000000 The array:75880085978171128220845485326336.000000 The array:752391028736.000000 The array:3509609299968.000000 The array:0.000000 The array:0.000000 " ...

" The array:0.000000 The array:0.000000 The array:0.000000 The array:0.000000 The array:0.000000 The array:nan The array:nan The array:0.000000 The array:nan The array:nan The array:nan The array:nan The array:nan The array:nan The array:nan The array:0.000000 "

- did this because it got back into setwayp function, and was told there were 7million waypoints to print by the wind sensor - the array is being corrupted -> memory management (aka declare all variables at the beginning of programs/functions) - I've labelled all my changes with // cb, things to work on tomorrow are labelled //cb!

March 5[]

(Sent to xbee pro and TS7260 manufacturers)

I am trying to do some initial tests of our Xbee Pro 802.15.4 chips with a micro-controller (TS-7260 by Technologic Systems www.embeddedARM.com)

The Xbee system works fine with two RS232 modules connected; one chip with a custom module connected to a loopback adapter and the other chip with a standard RS232 module connected to a computer running terminal (or X-CTU also works to do a range test). The custom module uses a 3.3V regulator (L7833) and a RS232 level converter (MAX3232EPCE).

The problem is a large current draw. When the loopback adapter is removed and the custom-module Xbee connected to the COM1 RS232 port of our microcontroller (via either a null-modem or straightthrough cable, both have been tried), the custom module and attached chip immediately draws 1.7A. This is beyond the limits of the regulated power supply it is using; I believe it is able to transmit, as the RS232 module's signal strength lights turned on when it is plugged into the microcontroller (semi-repeatable, lights dont turn on every time), but I do not wish to supply it with a higher current supply permanently. The microcontroller has been unable to communicate wirelessly through the connection.

The custom module draws 70mA when connected to the computer terminal or loopback- the high current is only seen when connected to the microcontroller.


Hopefully you have some trouble shooting ideas or solutions! Below are the Xbee-pro configuration values.

Cheers, Chris


Our xbee's are configured as follows:

Xbee 1, connected to computer: ATBD 7 ATVR 10A5 ATMY 0 ATID 3332 ATCH C ATDL 40003911 ATDH 13A200 ATND

(blank)

ATNI

(blank)

ATDN ERROR ATHV 1808 ATCE 1 ATVL MAX BOOTLOADER V 0Ald: Jul 25 2007 16:10:54l 26 2007 13:49:56


Xbee 2, connected to loopback/microcontroller: ATBD 7 ATVR 10A5 ATMY 0 ATID 3332 ATCH C ATDL 40003532 ATDH 13A200 ATND

(blank)

ATNI

(blank)

ATDN ERROR ATHV 1080 ATCE 0 ATVL MAX BOOTLOADER V 0Ald: Jul 25 2007 16:10:54l 26 2007 13:49:56

April 17[]

> I looked a bit into the wind sensor, the problem might be how the
> microcontroller reads the data, ie which UART converter it has, as the
> wind sensor isn't really RS232. Here's my references and notes from
> the research I did:
> power: 1A fast-blow fuse; 12VDC +/-3 -> power with two batteries; 1/2A
> draw
> http://airmartechnology.com/uploads/wiringdiagrams/91_864.pdf wiring
> diagram
>
> http://www.cruisersforum.com/forums/f13/nmea-0183-and-rs-422-vs-rs-232-a-12967.html signal
> output, grounds have to be floating. "if you want to use RS422 in a
> grounded system, then just ground the receivers negative signal, the
> output ( talker)s "-" (negative) is left disconnected. Both talker and
> receiver must be on a common power ground. (which is usually the case)."
>
> http://www.sailnet.com/forums/electronics/61887-nmea-0183-rs232.html more
> about potential NMEA problems, which two cables to connect
>
> http://en.wikipedia.org/wiki/Gpsd NMEA parser?
>
> http://www.gpsinformation.org/dale/nmea.htm nmea info


from what I know NMEA sends data using RS485, the microcontroller does not support BAUD 4800 in RS485 mode. One thing I'm thinking about is sending the wind sensor readings to the computer and then the computer relays them to the
microcontroller, if it's legel to do so.

Feb 5[]

http://www.microtransat.org/publications.php all about robot sailboats

http://www.riocean.com/ioshop/specs/Airmar_PB150_Manual.pdf weather beacon (wind speed etc) manual> http://www.tntc.com/Products/RevolutionGS.htm compass manual

http://www.embeddedarm.com/documentation/ts-7260-manual.pdf micro-controller manual

http://www8.garmin.com/manuals/237_TechnicalSpecifications.pdf GPS manual

http://www.libelium.com/squidbee/upload/3/31/Data-sheet-max-stream.pdf Wireless communication receiver manual
http://www.roboteq.com/files_n_images/files/manuals/ax500man19b-060107.pdf AX500 motor controller (for DC motors.. this one is not used, but we have it lying around)

http://www.rmgsailwinch.com.au/rmg/pdf/SmartWinchUserGuide0709.pdf


Nov 20[]

Wind speed and direction:

http://www.riocean.com/ioshop/specs/Airmar_PB150_Manual.pdf p.23 - 12V, 0.5A for weather station max http://www.marine-electronics-unlimited.com/Furuno+PB150+Weather+Station.htmlsupply current <150mA; 12VDC = 1.8W Compass:http://www.tntc.com/Products/RevolutionGS.htm5mA standby, 45mA operating, 15mA sample @ 5VDC -> 0.5W max, 0.06W standby GPS:whats the part number?


Oct 7[]

Waterproofing connectors:

The easiest solution here is to just use marine grade connectors:

'NMEA Starter Kit - N2K EXP RD2 ' from west marine is a good example.

If the connections are semi-permanent then go with:

MG Chemicals Silicone Conformal Coating Cat # 422-55ml. This stuff is amazing for waterproofing electronics. I’ve seen brushless motor ESCs work while submerged in water with this stuff. http://www.mgchemicals.com/products/422a.html It smells pretty toxic though.. apply outdoors.




Increasing RC controller range:

I’m super surprised to hear you’re having problems with this. You can typically sail an RC sailboat out of visual range, even with low power binoculars. If you’re trying to transmit more than just RC data then I see how it might be hard. You are running an antenna up the mast right?? Also many people holding the transmitter try and point the antenna at the boat / plane /car. Dipole antennas emit the strongest perpendicular to the antenna, ie hold it straight up. If we still have trouble we can pretty easily build/buy an RF amp. If you are looking for super long range (over the horizon or for crossing the Atlantic) any pilot will tell you to go with Low Frequency ~ 100-500 kHz. RC controllers are typically 75MHz.



Power consumption and reduction:

I wouldn’t think there is much you can reduce on a sailboat. Building a voltmeter isn’t too bad but the problem is that the battery voltage drops with the current being drawn. A simple and effective solution is to measure the average power being drawn on shore, know the capacity of our batteries and use a timer. However, this is rather unprofessional. You can get such high capacity these days for low weight that it might be a good idea just to overdesign the batteries. Two of these: http://www.all-battery.com/polymerli-ionbattery37v11000mah7872185.aspx would power you for like a week. 32$ each is super cheap! Throw on one of these meters and send the signal to the MC and you’ve got a complete solution. http://cheapbatterypacks.com/?menu=B94GDDD543&sid=11161



GPS

If you aren’t already using a 5Hz GPS then I would consider switching. Compared with a standard 1Hz you should get 2.25times (sqrt(5)) better resolution (I think..).



Sweet website:

This site is run by the editor of wired magazine. Tons of useful info on DIY UAVs. http://diydrones.com

Advertisement