Arctic Hare mod by Jussi

After autocalib compas theres no accelerate, mower almost jump forward
Yes (y) I need to add a state to accelerate.
should I turn off mow motors during calib.
Like you want
You need to check the console:
search for FINDYAWSTOP and check that the 4s is OK directly on first time
If Yes you can leave the mow motor, if no try without and use the best solution.
Adjust also the Roll speed to find YAW ,not fast to find yaw on first roll (into setting IMU)

Here one console as example.
 

Anhänge

  • 1console.txt
    35,7 KB · Aufrufe: 4
Like this?
Code:
[07:01:54 4.000889] NORMALMOWING / FINDYAWSTOP
[07:01:55 1.589486]  imu.comYaw 152.66 imu.ypr.yaw 120.27 distancePI(imu.comYaw, imu.ypr.yaw) 2.73
[07:01:55 0.023070] NORMALMOWING / ROLLTOFINDYAW
[07:02:02 6.950744] NORMALMOWING / STOPCALIB
[07:02:02 0.081795] NORMALMOWING / AUTOCALIB
[07:02:07 4.673156] 4 sec of read value, verify if the drift is stop
[07:02:07 0.014966] Drift is OK
 
RTC errors driving me nuts. I have 7 modules and 5 work sometimes and sometimes not, 2 not work at all. If it's pcb's i2c-bus fault, IMU and eeprom should be faulty too? mower stop to error right after 'checktimer', otherwise it works well
Ordered ds3231 adafruit module, https://www.adafruit.com/product/3013 lets see what happen with that if I get it work
 
3 or 4 years ago i migrate a PCB1.2 to 3.3V and Arduino DUE,so i need to use a 3.3V module DS3231.
I order only one of these RTC and it work perfectly (y)

But if i remember well you need to make change in the code : the I2C adress is different.
I try to find the old parts of code but i am not sure !!!
 
imu or odo fault? it goes kinda arcs and then turns to zombie. on perimeter reaction is slow, best seen at 1:10->
 
If imu use is set to YES ,It's IMU fault (ODO is not use in straight line if IMU is activate)
But certainly I2C trouble (I never see this kind of behaviour).It's like the GYRO give a result totaly wrong.

What 's append at the end of video ?

Here what i note 3 years ago for DS3231.
// ------- I2C addresses --------------------------------------------------------------
#define DS1307_ADDRESS B1101000 //0x68
#define AT24C32_ADDRESS B1010000 //0x50 //normal use ds1307 memory module
//#define AT24C32_ADDRESS B1010111 //0x57 //for ds3231 default memory module. If A0 A1 A2 are shunt the adress become 0x50 and compatible with Ds1307
 
IMU is enabled. End of video mower went over perimeter as zombie then watchdog reset
Yes, I'm trying next connect rtc/eeprom and imu to I2C1. It should bypass pcb electronics. or maybe using two i2c channels? imu to other and rtc/eeprom to other
Did you change anything else? libraries, functions etc?
Code:
DS3231 has a default I2C address of 0x68 and cannot be changed
 
Yes, I'm trying next connect rtc/eeprom and imu to I2C1
Certainly a good idea but to use i2c1 you need a lot of change in the code.

First you can Simply connect the DS3231 instead of DS1307 and test by Simply changing the i2c adress of the eeprom into mower.h
The RTC have Always 2 I2C adress ,one for clock and one for eeprom.
DS1307 use 0x68 and 0x50
DS3231 use 0x68 and 0x57
 
Ok, ds3231 has eeprom also? cool :cool:
What changes? I was thinking about just changing pins?
Code:
// Mega2560/Due pins
#define SDA 20
#define SCL 21
 
Changing pin is not OK.
Take a look at kicad it's SDA1 and SCL1 from DUE (reserve pin not manageable) and you need to use the wire1 Library,
So all the file i2c.h and i2c.dev need change to acces to RTC
and i2cdev.cpp and i2cdev.h to IMU access.

It's really better if it can work on normal i2c
I really spend a lot of time to make the GY87 work on I2C1 connector.
 
What options I have for IMU? I think it's broken because mower seems to work now w/o imu. I'm 100% sure yet, I had only 45 min. battery left but no errors nor zombie
 
GY87 from marotronics connected on I2C1
Work for me on my RL1000 since 2 or 3 weeks without difference with GY88
For the code you need to replace :
IMU.cpp
IMU.h
all I2C.... .h and .cpp
all mpu6050.... .h and .cpp
By the version locate into robomowGy87 branch
and add wire1.begin into mower.cpp
Code:
 Console.begin(CONSOLE_BAUDRATE);
  I2Creset();
  Wire.begin();
  Wire1.begin();
  // Flash.test();
 
Ok, thanks (y) gy-87is much cheaper but specs are the same.. There's also 'no compass' -code with gy-521, is that working or not? I have a few gy-521's laying around from another project (iSpindel.de)
 
Are you sure the AD0 shunt is OK on your GY88 (If not the MPU6050 have the same adress as the RTC and generate i2C issue)

Yes GY521 work with the gyro-only branch locate in GitHub. ;)
In fact you Simply need a MPU6050 with correct I2C adress.
Without compass, the drift is not adjust, so the heading can change over time.
 
Shunt is ok. but what happened here? mower stopped and power down after delay
Code:
[08:06:32 14.560951] Perimeter trigger at : 55711635
[08:06:32 0.006125] NORMALMOWING / POUTSTOP
[08:06:32 0.004435] checktimer
[08:06:32 0.002199] Timer 1 startmin 420 stopmin 1260 currmin 486
[08:06:33 1.507873] NORMALMOWING / POUTREV
[08:06:36 2.601020] NORMALMOWING / POUTROLL
[08:06:37 0.000068] 
[08:06:37 0.000528]  MAIN MENU:
[08:06:37 0.001482] 1=test motors
[08:06:37 0.001746] To test odometry --> use Arduremote
[08:06:37 0.003954] 3=communications menu
[08:06:37 0.002444] To calibrate GYRO --> use Arduremote Do not move IMU during the Calib
[08:06:37 0.009467] To calibrate Compass --> use Arduremote start/stop
[08:06:37 0.005463] 9=save user settings
[08:06:37 0.002304] l=load factory settings: Do not save setting before restart the mower
[08:06:37 0.007785] r=delete robot stats
[08:06:37 0.002318] x=read settings
[08:06:37 0.001788] e=delete all errors
[08:06:37 0.002197] 0=exit
[08:06:37 0.000932] 
[08:06:37 0.000188] resetErrorCounters
[08:06:37 0.002134] Save ErrorCounters
[08:06:38 0.434575] ErrorCounters address Start=500
[08:06:38 0.003605] ErrorCounters address Stop=523
[08:06:38 0.003376] Save Robot Stats
[08:06:38 0.513899] Robot Stats address Start = 800
[08:06:38 0.006131] Robot Stats address Stop = 826
[08:06:38 0.005685] WAIT / OFF
[08:06:38 0.002227] ALL ERRORS ARE DELETED
[08:06:38 0.004397] 
[08:06:38 0.000328]  MAIN MENU:
[08:06:38 0.002360] 1=test motors
[08:06:38 0.002754] To test odometry --> use Arduremote
[08:06:38 0.006556] 3=communications menu
[08:06:38 0.004155] To calibrate GYRO --> use Arduremote Do not move IMU during the Calib
[08:06:38 0.015205] To calibrate Compass --> use Arduremote start/stop
[08:06:38 0.009304] 9=save user settings
[08:06:38 0.003945] l=load factory settings: Do not save setting before restart the mower
[08:06:39 0.012703] r=delete robot stats
[08:06:39 0.003965] x=read settings
[08:06:39 0.003068] e=delete all errors
[08:06:39 0.003845] 0=exit
[08:06:39 0.001601] 
[08:06:39 0.000324] resetErrorCounters
[08:06:39 0.003597] Save ErrorCounters
[08:06:39 0.417264] ErrorCounters address Start=500
[08:06:39 0.003527] ErrorCounters address Stop=523
[08:06:39 0.003381] ALL ERRORS ARE DELETED
[08:06:39 0.002561] 
[08:06:39 0.000188]  MAIN MENU:
[08:06:39 0.001377] 1=test motors
[08:06:39 0.001582] To test odometry --> use Arduremote
[08:06:39 0.003852] 3=communications menu
[08:06:39 0.002387] To calibrate GYRO --> use Arduremote Do not move IMU during the Calib
[08:06:39 0.007162] To calibrate Compass --> use Arduremote start/stop
[08:06:39 0.005246] 9=save user settings
[08:06:39 0.002247] l=load factory settings: Do not save setting before restart the mower
[08:06:39 0.007163] r=delete robot stats
[08:06:39 0.002250] x=read settings
[08:06:39 0.001782] e=delete all errors
[08:06:39 0.002147] 0=exit
[08:06:39 0.000914]
 
Now I can confirm that it's working with gy-521. Ordered gy-87 also, why you use it in i2c1? address issues maybe?
 
Wifi issues, only solution, for now, is usb dongle with a different chipset. My 3b+ freeze many times per day and it freeze due also. Zero w is stable, that's why I'm trying to rip all graphics off and run only console version.
Code:
May 28 07:03:42 ArduMowerPi kernel: [63496.887606] brcmfmac: brcmf_cfg80211_scan: scan error (-110)
May 28 07:04:42 ArduMowerPi kernel: [63556.888014] brcmfmac: brcmf_run_escan: error (-110)
 
Oben