Questions tagged [programming]
Questions about programming the various LEGO programmable bricks, including Mindstorms (Robot Inventor, EV3, NXT, and RCX), Wedo, Spike and Scout, in either the provided languages and editors, or more advanced languages.
221
questions
0
votes
0
answers
23
views
How can I program two ev3 bricks at the same time with one program? [duplicate]
I want to be a program two EV3 bricks in Lego Mindstorms Education Ev3 software
0
votes
0
answers
53
views
Programming Lego Technic with Python using BLT bytes [duplicate]
I have a LEGO Technic 42124 Off-Road Buggy. It has remote control capability via Bluetooth, and I want to control my car using a computer. So, I want to write a Python script like this:
from bluepy ...
3
votes
1
answer
313
views
Please help me: Sending String from PyCharm via usb to NXT, which is programmed by Bricx CC
I am new on this platform and hope for some help.
I am doing a school project right now and we are working with Lego Mindstorms NXT and write the program with the Bricx Command Center. I know that ...
3
votes
2
answers
844
views
Connecting a Lego PF M motor to computer
Can you connect the Lego Power Functions M motor to a computer with USB?
1
vote
0
answers
49
views
How to fix LEGO Mindstorms error code 5003?
I was using the NXT programming app and tried to download the file to the NXT, but it showed "Error code 5003". What is this error and what could I do to resolve it?
3
votes
1
answer
70
views
Detect stalling Motor in the new EV3 Education Classroom
I have a gripper that should automatically stop closing when an object is grabbed. I achieved this in the older EV3 Home Edition by reading the motor current and comparing it to normal values. If it ...
2
votes
0
answers
46
views
How do I get a variable and image into the Lego Mindstorms EV3 image editor
I am making a project and I want the EV3 brick to have a GUI-like interface. It also needs to display a variable on the GUI. Is there a way to draw the GUI and have the live variable reading as well? ...
1
vote
1
answer
53
views
How do I make apps in Lego Mindstorms EV3 Education?
In the EV3 manual, it says you can create custom apps, in the same page as the IR control and Port View. How do you make a new app? I found a button under tools which says "Download as app", ...
2
votes
1
answer
120
views
What is the difference between LOCAL memory for programs and LOCAL memory for Direct Commands?
I've learned a bit about Direct Commands in EV3 and understood the work of Local and Global memory. Using the Direct Commands I can access the memory using an offset of the accessing byte/bytes (like ...
5
votes
2
answers
320
views
Does LEGO make a electronically controlled pneumatic valve bank?
I've decided to try my hand at building a working LEGO Concrete Block Making Machine, as shown in this picture:
with the idea being that the machine will be controlled by both manual and automatic ...
3
votes
1
answer
108
views
Problem with emulating EV3 brick via wifi
I'm trying to emulate Lego EV3 brick connection via wifi. First I found the repo and rewrote it a bit in C# so now I have this:
LabVIEW.cs
public class LabVIEW
{
public string Serial { get; set; }
...
3
votes
0
answers
372
views
LEGO Studios Movie Maker Camera (1349) (2000)
A few months back I had purchased the LEGO Studios Movie Maker Set (1349) and have been tampering with it, specifically the camera, to see if I can get it to work on my Windows 11 laptop. Was able to ...
1
vote
1
answer
86
views
Mindstorms program error when I play in download mode
I can run the program perfectly in the streaming mode, but it will flash a red light in the download mode after getting 5 points. Below is my program code:
...........Updated.............
Finally I ...
2
votes
1
answer
101
views
Direct command to set EV3 motor speed
I am trying to set a EV3 motor's speed and start it remotely using a direct command. Using the resources LEGO MINDSTORMS EV3 Communication Developer Kit (page 24) and LEGO MINDSTORMS EV3 Firmware ...
0
votes
1
answer
878
views
How I can connect the LEGO SPIKE Prime hub via Bluetooth in Visual Studio Code using the pybricksdev library?
I'm trying to send some data from the hub to the terminal for some debug. But I can't figure out how I can connect the hub via Bluetooth to my PC. I tried to look in the API documentation and maybe I ...
4
votes
2
answers
353
views
What is the gyro sampling rate on the Spike Prime hub?
I was wondering what is the inertial measurement unit sampling rate, because for my project I need 800 Hertz. I tried to look in the firmware file but I didn’t find anything. I use the pybricks ...
4
votes
3
answers
164
views
Is it possible to have a motor default to a certain position at the start of the code? I'm trying to use the motor as a servo, and it's annoying
The motor is attached to a "door", which rotates to block off an opening. I have it coded to manually go back 1/4 of a rotation, and the distance sensor attached will send it forwards 1/4 of ...
2
votes
0
answers
174
views
Mindstorms M.V.P. model doesn't move
I'm a total newbie to Mindstorms 51515.
I am trying to program my M.V.P. model and everything seems to work except the movement programming blocks (pink). Does anyone have a hint or a clue about what'...
6
votes
3
answers
7k
views
Is it possible to re-flash the LEGO Spike Prime Hub with Mindstorms Robot Inventor Hub Firmware while retaining all functionality? And if so, how?
Unfortunately, LEGO has recently announced that after 24 years, the Mindstorms line of Robotics Kits is officially being discontinued at the end of this year. For this reason, the 51515 Robot Inventor ...
4
votes
2
answers
235
views
How to change colour of the bluetooth/charging RGB LED in the hub?
I have the Mindstorms set 51515 - Robot Inventor. I want to display the progress of a robot's work using the LEDs.
How can I change the colour of the RGB LED that the hub uses to indicate the ...
5
votes
1
answer
395
views
How do I copy blocks in LEGO 51515 block IDE?
I have been trying to copy and paste blocks in the new IDE that I downloaded from the Microsoft store (v 10.3.1). I do not seem to be able to copy block code from one project to another. How can I ...
4
votes
1
answer
125
views
Accessing an EV3 brick on computer without MINDSTORMS Home
I am trying to hack my EV3, and I know I can make it execute commands I send via USB thanks to the communication developer kit.
When I connect it via USB, it is only visible by the MINSTORMS Home app ...
3
votes
1
answer
292
views
How to cross compile for ev3dev using Docker
How to add ev3dev libraries/headers to docker cross-compile setup?
I have assembled ev3dev on BrickPi (with Raspberry Pi 1 - chip BCM2835). I think, it all should be pretty similar for EV3 brick too. ...
7
votes
1
answer
286
views
Looking for a PC controlled motor that allows for very small and precise movements
The image below is a LEGO specimen stage designed for a stereo microscope. I am looking for a recommendation for a PC controlled motors that allows for very small and precise movements.
I want use ...
3
votes
1
answer
133
views
When using Mindstorms Scratch-like development tool for EV3, is it possible to move a single or a few selected blocks somehow?
Say I have 10 random blocks in a line.
Is it possible to move number 4 to position 1 without also moving block 5-10?
As far as I have managed to move blocks all following blocks also gets moved even ...
2
votes
2
answers
329
views
Multiple Programming Blocks Running at Same Time
My team created a simple program to drive robot out. It consists of a MyBlock to drive straight a specified distance and speed utilizing the Gyro sensor. The program then activates a third large ...
3
votes
4
answers
2k
views
"Heads up! Could not open project" error message when opening project
When I try to open my project it gives me an error saying "Heads up! Could not open project". Could you please help me? Let me know if you want me to share the file.
We were working on the ...
4
votes
1
answer
943
views
Why did the light block change in SPIKE v2.0.0+?
I found Unofficial SPIKE Prime Block Guide, which has following details:
And if you open the SPIKE app (2.0.0 or newer), the light blocks were completely changed:
Is anyone able to explain why?
6
votes
1
answer
783
views
How to use REPL on the 51515 hub?
I've just got access to a 51515 Hub and I tried to connect to it as a serial port (with baudrate 115200), however it's spamming the console with motor/sensor data:
{"m":0,"p":[[62, ...
0
votes
0
answers
196
views
Ev3 classroom 1.5.2.0 not working
When I try to create a new project or open an old project, the program does not work.
We have 10 computers (desktops) with different versions of Windows 10
Stuck on this.
10
votes
1
answer
662
views
robotic inventor\spike prime hubs: Hub 2 hub communication AND led matrix control
Recently the Spike essentials set was released, including the very interesting 3x3 led matrix part:
The matrix allows to set each individual pixel in the 3x3 array to 10 different shades of 10 ...
6
votes
1
answer
359
views
Mindstorm 51515 If then else alternative - like a switch statement
Is there a way to act on multiple values for a variable? For example, x may be 1, 2, or 3. If then else allows for 2 conditions. Multiple "ifs" work, but is cumbersome.
Ideally I'd like a ...
2
votes
1
answer
75
views
How do you scroll the canvas in EV3 Classroom?
I have EV3 classroom installed on Mac. I am writing a pretty lengthy program that does not fit in a single screen. However, I am not able to figure how to scroll down or move sideways. This should be ...
1
vote
0
answers
184
views
"Heads up! Could not open project" error message in EV3 software [duplicate]
Whenever we try to edit one of our old projects our EV3 Mindstorms Home software shows us the "Heads up! Could not open project" screen. What should we do?
I am on the Mac OS Big Sur 11.2.3 ...
0
votes
1
answer
179
views
EV3G Where can I find the .vix file for the low-level functions? (Set integer, IO operations, start block)
They look like this:
By default, when you refer to a vix file, it looks like this:
<Reference Type="VILib" Name="TerminalTerminal.vix" />
But, to refer to these low-level ...
5
votes
1
answer
284
views
EV3 not recognizing resistance correctly (MicroPython)
I recently tried measuring the resistance of a thermistor using the .resistance() method, the results are sadly not accurate. I measured the resistance with a multimeter and it showed 100kΩ, while the ...
4
votes
1
answer
130
views
EV3-G custom block crashes when Switch statement is copied
My team and I are trying to convert our coding framework made of myblocks into actual blocks. I made an application, that generates a "shell" of the block (the modes, and parameters). After ...
3
votes
1
answer
489
views
Robot Inventor Bluetooth not working
A while ago, I started up the Robot Inventor program and noticed the computer was not connecting. When I clicked the "Connect" button, the loading "circle" simply started spinning ...
3
votes
3
answers
993
views
How to stop or freeze the EV3 large motor in position
How do I stop or freeze the large motor in a fixed position? I have a forklift type attachment that will lift to the precise height, but will not stay in position due to the weight of the attachment.
...
3
votes
0
answers
121
views
How do I import my programs from makecode (Chromebook) to my EV3 robot
While using makecode I wanted to import my file to my EV3 robot but it says that I have to connect my EV3 robot to my computer and then move the file to the robot. But since I'm on Chromebook I don't ...
4
votes
0
answers
54
views
How do I sync audio and movement on my NXT 2.0?
How do I sync audio and movement with my NXT 2.0? I'm building an animatronic head and I can't find a good way to sync it with external audio because the internal speaker is too quiet.
0
votes
1
answer
74
views
Program just stops motors and won't move
I'm trying to make a program in the NXT software that turns on the motors unlimited, then waits until something is less than 30 cm, stops the motors, turns to the left 30 degrees and saves the value ...
4
votes
0
answers
253
views
Migrate Lego Boost Android app data to another device
I have a Lego Boost Android application installed on device #1 and the app is logged into my LEGO cloud account (the same used for Lego Life etc. too) and is fully synced with cloud. On this device I ...
13
votes
2
answers
4k
views
Where can one find the documentation for the LEGO Mindstorms Robot Inventor software?
Is the documentation (either official or unofficial) of the programming "language" for the LEGO Mindstorms Robot Inventor software available somewhere? Preferably online, without requiring ...
2
votes
2
answers
786
views
How to get a random value in the Robot Inventor software (Python)
I am making a Python program with the LEGO Robot Inventor software which will, among other things, turn the robot a random amount periodically, which of course requires a random number. However, I ...
4
votes
1
answer
584
views
When using pi * distance between wheels/tracks, how do I measure distance between wheels?
I am trying to make a program that requires my 51515 to turn a specified number of degrees. I found a way to do that on the LEGO app's "Knowledge Base", but the given example was:
import ...
9
votes
2
answers
2k
views
Programming on a chromebook with EV3
How do I install the new Lego block programming software on a chromebook? We have the standard version, but want the new one that looks like Scratch.
8
votes
1
answer
283
views
Help with my Ev3 printer
I'm building an image printer using my ev3 set and several more pieces, as a project to keep me occupied while I'm stuck at home.
Here's how it looks:
I've done the build part, the way I've chosen to ...
0
votes
1
answer
171
views
Using Power functions to teach robotics
I am a robotics engineer and I would like to introduce and teach my girlfriend to robotics. I would like to first get her the material for the first project. I would love to build a small Lego car ...
6
votes
1
answer
413
views
Why doesn't my LEGO Micropython remote control program work?
I am writing an EV3 micropython program meant to test my remote, but it does not work. When I run it, I see no errors at all. Instead, I just see a "play" symbol and the program continuously ...