Hi
I have tried all the way to solve this issue to coonect to components to the module. It doesnot connect at all, tried all snap scenarios.
Can you plz look into my schematics and suggest me the way to come out of this?
Thanks in advance for your support.
Below is the link of my project..
https://easyeda.com/editor#id=|b4e4e369a3394342943705df87c665fa|4f8aa0e6b4444c9c989dd7abe2e45890
#Schematic#Hi all,
assuming i have a list of all component names and their (center) X/Y position in mil from the PCB origin as well as their origins.
Now I want to programmatically position all components in the PCB layout at the given positions w/ their rotation.
(as if I trained a monkey selecting manually a component by its name and enter the X/Y values)
So i have a bunch of hurdles and questions, I hope some can be answered by you :)
I tried fetching the source using api('getSource', {type: "json"});
-> result: got all important information. but... every single drawable entity with their subentities and texts and arcs and stuff etc has its absolute position in there.
I would have to fully understand the mechanics of what is a LINE and an ARC and TEXT and PAD and must not forget a single unexpected item there.
[Bug?] Tried to get the real position like in the examples using api('coordConvert', {type:'canvas2real',x: 10})
-> result: i was not able to convert "mil" or "mm" units into the "real" coordinates, as the API call is crashing:
message: "getPCBUnit is not defined"
stack: "coordConvert@https://easyeda.com/editor/6.4.7/js/main.min.js:18:19407
edit: Oh no! Most of the post vanished. It was cut right in the middle of the stackdump. darn.
Questions:
1. how to set the rotation *absolute* ?
2. how to get the current X/Y/rotation?
3. how to select a component by its name (like "R12")?
4. what would be your preferred approach to set component positions?
Thats my current test code:
api('moveObjsTo', { objs:["gge5d7d37af6db8001c"], x:4000, y:3000}); // manually set position to origin
api('rotation', {ids:["gge5d7d37af6db8001c"], degree:90});



in a much smaller 3D image, even though the 2D footprint is correct after pressing AUTO
