KR2 ROV
Re: KR2 ROV
Loving your LED control in the previous post!
What method are you using to increase the value in arduino?? it's a nice smooth count up and down!
Also what batteries are you using? 3s or 4s?
What method are you using to increase the value in arduino?? it's a nice smooth count up and down!
Also what batteries are you using? 3s or 4s?
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: KR2 ROV
Hey Bindo,
Thanks for the comments!
I send both of these values via the EasyTransfer Library from the Topside to the Bottom side Arduinos. The LED Drivers that I have allow for a PWM signal to control brightness.
Here is the Driver details:
Meanwell DC-DC Constant Current Step Down LED Drive part number: LDD-500L
Here are the LED Details:
Bridgelux BXRA-56C1100-B-00
Here is the code from that section of my program:
TOP SIDE:
BOTTOM SIDE:
Thanks for the comments!
I have two key variables that affect the performance of the External Lighting LEDs; "iluminateState" and "brightness".Bindo wrote:What method are you using to increase the value in arduino??
I send both of these values via the EasyTransfer Library from the Topside to the Bottom side Arduinos. The LED Drivers that I have allow for a PWM signal to control brightness.
Here is the Driver details:
Meanwell DC-DC Constant Current Step Down LED Drive part number: LDD-500L
Here are the LED Details:
Bridgelux BXRA-56C1100-B-00
Here is the code from that section of my program:
TOP SIDE:
Code: Select all
// Set brightness of ROV External lighting and state of lights
//Start Button = On/Off
if(ps2x.ButtonReleased(PSB_START)) {
if(IlluminateStatus == true){
IlluminateStatus = false;
drawDots = false;
txdata.ET_iluminateState = 0;
analogWrite(light[0], 0);
analogWrite(light[1], 0);
analogWrite(light[2], 0);
}
else {
IlluminateStatus = true;
drawDots = true;
txdata.ET_iluminateState = 1;
analogWrite(light[0], brightness);
analogWrite(light[1], brightness);
analogWrite(light[2], brightness);
}
}
// PAD UP = Brightness UP and PAD DOWN = Brightness Down
if(ps2x.Button(PSB_PAD_UP) && (brightness < 255)) {
brightness = brightness + 2; //Change this value (2) to chance the speed of the increase/decrease
if (brightness > 255) {brightness = 255;}
}
if(ps2x.Button(PSB_PAD_DOWN) && (brightness > 0)) {
brightness = brightness - 2;
}
txdata.ET_brightness = brightness;
Code: Select all
// Set brightness of ROV External lighting and state of lights
if(rxdata.ET_iluminateState == 1) {
drawDots = true; //Turn on dots to show lights are ON
analogWrite(light[0], rxdata.ET_brightness); //Set Brightness of each light
analogWrite(light[1], rxdata.ET_brightness);
analogWrite(light[2], rxdata.ET_brightness);
}
else {
drawDots = false;
analogWrite(light[0], 0);
analogWrite(light[1], 0);
analogWrite(light[2], 0);
}
At the moment, I am planning on using three 3s 5500mAh batteries. 2 will be for the motors, I am thinking of running them in parallel, and 1 will be for the controls/sensors/lighting.Bindo wrote:Also what batteries are you using? 3s or 4s?
Re: KR2 ROV
loving it
you must have a small-ish set of delays in your code? (approx 100ms?) looking at the way it counts?
10 updates per second is more than enough though! i found through experimentation that anything near 200ms was far too much and prop speed changes became less fluid and more robotic.
you must have a small-ish set of delays in your code? (approx 100ms?) looking at the way it counts?
10 updates per second is more than enough though! i found through experimentation that anything near 200ms was far too much and prop speed changes became less fluid and more robotic.
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: KR2 ROV
So I am back at it again... the future Ms. is out shopping for wedding dresses... so I figured it was as good a day as any to blow the dust off this never ending project and see if I can make some progress! There has been some other day projects here and there since my last post. So i will first start with a quick update.
1. I've designed a skeleton base for my ROV. I will be mounting my 4" WTC and 6 BR thrusters to this. 2. I've designed a basic chassis to mount electronics to inside my 4" WTC and started populating it with components. This really helped clean up the work space and condense the Subside electronics. 3. I've mocked up a TopSide control station, containing the topside Arduino and Qty 8 7-seg displays for monitoring things while diving. Currently, displays Thruster values, raw data from PS2 controller and LED brightness and state. Also cleaned up work space a bit more! 4. I put together some distribution PCBs for the Thruster Power and coms... not sure I will go with this design in the final ROV, but i think it will work... hoping to test soon! I have run into what may be a bigger problem later on as I add in my Subside sensor packages. It seems between the EasyTransfer library and OSD refresh/print lag, it loose about 50ms per scan on the arduino... not sure this is an issue yet... but I am afraid it might be... even Bindo noticed this.
Anyone who has played with the EasyTransfer Library... have you found a good and STABLE way to eliminate the 10ms delay in the loop on the data receive function?
Alternatively, anyone have any suggestions on how to speed up the OCD refreshing?
Here is what the display looks like IRL at the moment.
Anyway... thats the progress I've made here over the last few months...
Happy Diving!
Ryan
"KR2_DIVING"
1. I've designed a skeleton base for my ROV. I will be mounting my 4" WTC and 6 BR thrusters to this. 2. I've designed a basic chassis to mount electronics to inside my 4" WTC and started populating it with components. This really helped clean up the work space and condense the Subside electronics. 3. I've mocked up a TopSide control station, containing the topside Arduino and Qty 8 7-seg displays for monitoring things while diving. Currently, displays Thruster values, raw data from PS2 controller and LED brightness and state. Also cleaned up work space a bit more! 4. I put together some distribution PCBs for the Thruster Power and coms... not sure I will go with this design in the final ROV, but i think it will work... hoping to test soon! I have run into what may be a bigger problem later on as I add in my Subside sensor packages. It seems between the EasyTransfer library and OSD refresh/print lag, it loose about 50ms per scan on the arduino... not sure this is an issue yet... but I am afraid it might be... even Bindo noticed this.
To overcome this for the moment, I have added a toggle that turns the OSD on and OFF... but I am hoping to find a more efficient fix without loosing functionality.Bindo wrote:you must have a small-ish set of delays in your code? (approx 100ms?) looking at the way it counts?
Anyone who has played with the EasyTransfer Library... have you found a good and STABLE way to eliminate the 10ms delay in the loop on the data receive function?
Code: Select all
//--------------------------------------------------------------------------------------------
// Receive Data via EasyTransfer
//--------------------------------------------------------------------------------------------
//there's a loop here so that we run the receive function more often then the
//transmit function. This is important due to the slight differences in
//the clock speed of different Arduinos. If we didn't do this, messages
//would build up in the buffer and appear to cause a delay.
for(ETloop = 0; ETloop < 5; ETloop++){
//remember, you could use an if() here to check for new data, this time it's not needed.
ETin.receiveData();
delay(10);
}
if(ETin.receiveData()){
lastMessage = millis();
goodComs();
}
else{
if(millis() - lastMessage >= timeout) {
badComs();
}
}
Code: Select all
// OSD Display Update
if(currentTime >= (cloopTime + 1000))
{
cloopTime = currentTime; // Updates cloopTime
hours = Tcounter / 3600;
mins = (Tcounter % 3600) / 60;
secs = Tcounter % 60;
char diveTime[8];
sprintf(diveTime,"%2d:%02d:%02d",hours,mins,secs);
if(rxdata.ET_osdState == true){
OSD.setCursor(17,0); OSD.print(" "); OSD.setCursor(17,0); OSD.print(diveTime);
}
Tcounter++;
}
//OSD.setCursor(17,1); OSD.print(" "); OSD.setCursor(17,1); OSD.print(currentTime);
//OSD.setCursor(0,8); OSD.print("012345678901234567890123456789");
if((currentTime >= (ocdLoopTime + ocdRefresh)) && (rxdata.ET_osdState == true)){
ocdLoopTime = currentTime; //update ocdLoopTime
OSD.setCursor(0,9); OSD.print(" "); OSD.setCursor(0,9); OSD.print(rxdata.ET_FORPORT);
OSD.setCursor(23,9); OSD.print(" "); OSD.setCursor(23,9); OSD.print(rxdata.ET_FORSTBD);
OSD.setCursor(4,10); OSD.print(" "); OSD.setCursor(4,10); OSD.print(rxdata.ET_VERT_LF);
OSD.setCursor(19,10); OSD.print(" "); OSD.setCursor(19,10); OSD.print(rxdata.ET_VERT_RT);
OSD.setCursor(0,11); OSD.print(" "); OSD.setCursor(0,11); OSD.print(rxdata.ET_AFTPORT);
OSD.setCursor(23,11); OSD.print(" "); OSD.setCursor(23,11); OSD.print(rxdata.ET_AFTSTBD);
}
Happy Diving!
Ryan
"KR2_DIVING"
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: KR2 ROV
Ok... Bit more progress! I was getting antsy and wanted to mock out the frame to see how how the thrusters and WTC come together!
All in all... I can say am quite happy with how it is coming together!
I still need to figure out where I am going to house the batteries. Likely will be 2 x 2" WTC from BR with my batteries and power distribution mounted in side. Might just go with the end caps and use WHITE PVC... still deciding... like the idea of Acrylic for visual inspection... and it just looks cooler! BUT... it is $65 buck more than I really need to spend...
Will keep you posted!
Happy Diving!
All in all... I can say am quite happy with how it is coming together!
I still need to figure out where I am going to house the batteries. Likely will be 2 x 2" WTC from BR with my batteries and power distribution mounted in side. Might just go with the end caps and use WHITE PVC... still deciding... like the idea of Acrylic for visual inspection... and it just looks cooler! BUT... it is $65 buck more than I really need to spend...
Will keep you posted!
Happy Diving!
Re: KR2 ROV
Don't you need to turn the horisontal thrusters 90 degrees?
The way they are now your rov will not be able to turn arround its own axis.
The way they are now your rov will not be able to turn arround its own axis.
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: KR2 ROV
You are SO right! I knew something was looking off last night when I threw that all together!olegodo wrote:Don't you need to turn the horisontal thrusters 90 degrees?
Re: KR2 ROV
Only reason I noticed is that I have done the same mistake myself
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: KR2 ROV
Worked on the TimeSucker (name pending! ) a bit more over the weekend, and mounted the final 2 thrusters, and mocked up the battery compartments...
AND... I've spun the thrusters right way around!
AND... I've spun the thrusters right way around!
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: KR2 ROV
Hello All,
Been making some GIANT leaps in the progress of my yet to be named ROV.
Moved the build up to my parents place. They just completed an extension to their workshop, so i promptly moved in and claimed a corner as my own!
Just a bit more space and tools for the build here than my Chicagoland Apartment!
Over the weekend, I worked on the LED housings. I was worried about heat, so I managed to find a way to mount the LEDs on an aluminum plate, inside an aluminum pipe.
I have a few more details to sort out. Once I have completed the LED build, I will post some updates. IN summary, I found some Aluminum Pipe that i could use with the Blue Robotics 2" Flanges.
I still have what is proving to be a serious problem with power. The SUBSIDE controller (Arduino MEGA) seems to run fine when I power the set up from the USB port on my MAC, however, if I try to power from the SUBSIDE LiPo batteries, the system locks up and stops funcitoning... Still trying to figure that out... any ideas?
I'm running the LiPo (3 Cell) into the Vin Port on the Mega, which is suppose to allow 6 to 20VDC... The on-board Voltage Regulator gets VERY HOT... and I am wondering if this is what is causing things to lock up? Any thoughts?
Anyway, making lots of progress!
Been making some GIANT leaps in the progress of my yet to be named ROV.
Moved the build up to my parents place. They just completed an extension to their workshop, so i promptly moved in and claimed a corner as my own!
Just a bit more space and tools for the build here than my Chicagoland Apartment!
Over the weekend, I worked on the LED housings. I was worried about heat, so I managed to find a way to mount the LEDs on an aluminum plate, inside an aluminum pipe.
I have a few more details to sort out. Once I have completed the LED build, I will post some updates. IN summary, I found some Aluminum Pipe that i could use with the Blue Robotics 2" Flanges.
I still have what is proving to be a serious problem with power. The SUBSIDE controller (Arduino MEGA) seems to run fine when I power the set up from the USB port on my MAC, however, if I try to power from the SUBSIDE LiPo batteries, the system locks up and stops funcitoning... Still trying to figure that out... any ideas?
I'm running the LiPo (3 Cell) into the Vin Port on the Mega, which is suppose to allow 6 to 20VDC... The on-board Voltage Regulator gets VERY HOT... and I am wondering if this is what is causing things to lock up? Any thoughts?
Anyway, making lots of progress!