How to create an ellipse around Earth (satellite trajectory) ?

I would like to create an ellipse that goes all around Earth, to represent a satellite' trajectory. I would like to give it a center, a semi major axis, a semi minor axis, an inclinaison. I have done this code, but it gives something not perfectly around Earth, or not properly located. I haven't found any answers on the internet since a week of research.

Perhaps, I should locate the center with Cartesian Coordinates but I don't know how, it seems that all objects are located with longitude, latitude and not x, y,z on cesium.

position: Cesium.Cartesian3.fromDegrees(90, 0),
name : 'Green circle at height with outline',
ellipse : {
semiMinorAxis : 7000000.0,
semiMajorAxis : 11000000.0,
fill: false,
outline: true,
outlineColor: Cesium.Color.YELLOW,
outlineWidth: 2.0

}
});

Hi there,

When we render satellite trajectories in Cesium, we use Polylines with the pre-calculated positions. Here’s a quick example:

var viewer = new Cesium.Viewer(‘cesiumContainer’);

var semiMinorAxis = 7000000.0;

var semiMajorAxis = 11000000.0;

var positions = ;

for (var i = -180; i <= 180; i+=10) {

``````var axis = semiMinorAxis + Math.cos(i * Math.PI / 180.0) * (semiMajorAxis - semiMinorAxis);

positions.push(Cesium.Cartesian3.fromDegrees(i, 0, axis));
``````

}

``````polyline : {

positions : positions,

followSurface : true,

width : 4,

material : Cesium.Color.RED

}
``````

});

viewer.zoomTo(viewer.entities);

``

Thanks,

Gabby