Same for me. Since the rfid reader connected, the internal Speaker make PIEP every time.
I use M5Stack core, with the M5 rfid reader.
With this noise, the complete environment make non-sense...
Same for me. Since the rfid reader connected, the internal Speaker make PIEP every time.
I use M5Stack core, with the M5 rfid reader.
With this noise, the complete environment make non-sense...
Hi Felix,
no problem. Will try to find the error...
Thanks for your help!!
Hi Felix,
Vielen dank für Deine Unterstützung ! Sprichst du deutsch ?
Thanks for your help. I will try both options, and will send a feedback here.
Hello,
i have a M5Core device.
Yes, i switch from TX23 -> to TX17, and RX19 -> to 16. Thanks for this tip.
But, now i have a last question, see screenshot below.
I Arduino i write with Serial2.write(...) the Hex. How can i do this in the UIFLOW ?!
Please see screenshots...
Hope you can help me, with my last question...
Thats not work. The code hang on the line set UART...
Whats wrong ??
Hi Gents,
i have a Problem with my Servo module. I buy the M5Core 12 channel Servo modul, and connect my servo on Port 0 from the Modul, but the Servo not work.
I have a running example for the Arduino, which works well with the Servo. I think the problem is my logic to move the code from Arduino Uno to M5Core 12 Channel Servo modul.
That is working with Arduino Uno:
#include <SoftwareSerial.h>
SoftwareSerial mySerial(10, 11); // RX, TX
void setup()
{
Serial.begin(9600);
mySerial.begin(115200);
Serial.println("start");
}
void servo(char ServoId, char Mode, char Degrees, char Speed)
{
// Build checksum;
int sum = ServoId + Mode + Degrees + Speed;
char zero = 0;
while (sum > 255)
{
sum -= 255;
}
//Head (Preamble)
mySerial.write(0xFA); // Byte 1: Preamble;
mySerial.write(0xAF); // Byte 2: Preamble;
//Data
mySerial.write(ServoId); // Byte 3: ServoID (See label of servo)
mySerial.write(Mode); // Byte 4: Command; for “go to command” we have = 0x01; we will try to find some other commands shortly
mySerial.write(Degrees); // Byte 5: position = 120 + desired position in degrees;
mySerial.write(Speed); // Byte 6: duration = duration in ms / 20
mySerial.write(zero); // Byte 7: 0x00 (? we don’t know what this is yet)
mySerial.write(zero); // Byte 8: 0x01 (? we don’t know what this is yet)
//Check & End
mySerial.write(sum); // checksum = sum(byte 3 through 8) mod 256
mySerial.write(0xED); // closure = 0xED (from “END”?)
}
void loop()
{
servo(16, 1, 45, 40);
delay(2000);
servo(16, 1, 0, 10);
delay(2000);
}
And here i try move my code to M5Stack with 12 channel Servo Modul, which are not work on Port 0. Have any a idea ?
#include <Arduino.h>
#include <M5Stack.h>
#include <Wire.h>
#define SERVO_ADDR 0x53
void setup()
{
M5.begin(true, false, true);
M5.Power.begin();
M5.Lcd.setTextFont(4);
M5.Lcd.setCursor(70, 100);
M5.Lcd.print("Servo Example");
Wire.begin(21, 22, 115200);
}
void servo(char ServoId, char Mode, char Degrees, char Speed)
{
Wire.beginTransmission(SERVO_ADDR);
Wire.write(0x00);
// Build checksum;
int sum = ServoId + Mode + Degrees + Speed;
char zero = 0;
while (sum > 255)
{
sum -= 255;
}
//Head (Preamble)
Wire.write(0xFA); // Byte 1: Preamble;
Wire.write(0xAF); // Byte 2: Preamble;
Wire.write(ServoId); // Byte 3: ServoID (See label of servo)
Wire.write(Mode); // Byte 4: Command; for “go to command” we have = 0x01; we will try to find some other commands shortly
Wire.write(Degrees); // Byte 5: position = 120 + desired position in degrees;
Wire.write(Speed); // Byte 6: duration = duration in ms / 20
Wire.write(zero); // Byte 7: 0x00 (? we don’t know what this is yet)
Wire.write(zero); // Byte 8: 0x01 (? we don’t know what this is yet)
Wire.write(sum); // checksum = sum(byte 3 through 8) mod 256
Wire.write(0xED); // closure = 0xED (from “END”?)
Wire.endTransmission();
}
void loop()
{
servo(16, 1, 45, 40);
delay(2000);
servo(16, 1, 0, 10);
delay(2000);
}
Can anyone help me, please... ?
Same here. The M5 Docs are a nightmare!!
On every documentation, the syntax is wrong, and not work correctly!
😒
Hi Guys,
ihm new with M5Stack. I have a MCore2 and try compile this in visual code with plattform.io.
How i must use the code in Plattform.io ? If i compile the code, the device showing black screen.
Can anyone help me ?
Same for me. I upload the example sketch, but only black screen in Core 2.
OS: Mac Big Sur
// the setup routine runs once when M5Stack starts up
void setup(){
// Initialize the M5Stack object
M5.begin();
/*
Power chip connected to gpio21, gpio22, I2C device
Set battery charging voltage and current
If used battery, please call this function in your project
*/
M5.Power.begin();
// LCD display
M5.Lcd.print("Hello World");
}
// the loop routine runs over and over again forever
void loop() {
}
Result debug:
esptool.py v3.0-dev
Serial port /dev/cu.usbserial-0203EDF5
Connecting....
Chip is ESP32-D0WDQ6-V3 (revision 3)
Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
Crystal is 40MHz
MAC: 84:cc:a8:61:90:50
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 921600
Changed.
Configuring flash size...
Auto-detected Flash size: 16MB
Compressed 8192 bytes to 47...
Writing at 0x0000e000... (100 %)
Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.0 seconds (effective 10848.4 kbit/s)...
Hash of data verified.
Flash params set to 0x024f
Compressed 17104 bytes to 11153...
Writing at 0x00001000... (100 %)
Wrote 17104 bytes (11153 compressed) at 0x00001000 in 0.2 seconds (effective 899.1 kbit/s)...
Hash of data verified.
Compressed 413360 bytes to 171576...
Writing at 0x00010000... (9 %)
Writing at 0x00014000... (18 %)
Writing at 0x00018000... (27 %)
Writing at 0x0001c000... (36 %)
Writing at 0x00020000... (45 %)
Writing at 0x00024000... (54 %)
Writing at 0x00028000... (63 %)
Writing at 0x0002c000... (72 %)
Writing at 0x00030000... (81 %)
Writing at 0x00034000... (90 %)
Writing at 0x00038000... (100 %)
Wrote 413360 bytes (171576 compressed) at 0x00010000 in 3.2 seconds (effective 1031.9 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 129...
Writing at 0x00008000... (100 %)
Wrote 3072 bytes (129 compressed) at 0x00008000 in 0.0 seconds (effective 3453.6 kbit/s)...
Hash of data verified.
Leaving...
Hard resetting via RTS pin...
Re: Add Speaker.beep and Speaker.volume to Core2
Yes, please add. Looks also for this feature.